-- call_summon
-- Created by chengb Nov/4/2015
-- 技能: 召出召唤兽

return {
    apply = function(source, target, skillId, round, para, extra)
        -- 如果已经死亡了
        if source:isDead() then
            return {};
        end

        local summonId = para[1];
        SummonM.doSummon(summonId);

        return { source, };
    end,
    
    check = function(skillId, para)
        local summonId = tonumber(para);
        if true ~= SummonM.canDoSummon(summonId) then
            return { "summon_alive", summonId, };
        end
        
        return true;
    end,

    parse = function(desc)
        local arr = string.explode(desc, ",");
        return  { tonumber(arr[1]) };
    end,

    -- 解析技能描述
    parseDesc = function(source, skillId, desc, para)
        return desc;
    end,
}

